<div class="container">
	<div class="panel panel-primary clearfix">
	    <div class="panel-heading">
	       	<h3 class="panel-title">Select health fund type from list</h3>
	    </div>

	    <!-- Search section -->
	    <div class="panel-body">
			<div id="search" class="singleline">
				<form id="searchForm" name="searchForm" method="POST" action="<?=$_SERVER['REQUEST_URI']?>">
					<a href="javascript:void(0)" class="reset" id="reset" onclick="resetForm('searchForm')">
						<div class="reset-filters">Reset filters</div>
					</a>
					<div class="search_filter">
						<p>
							Search by: <input type="text" name="keyword" id="keyword" value="<?=$_POST['keyword']?>">
							<input type="submit" value="Submit" class="btn">
						</p>
					</div>
					<div class="search_checks single">
						<input type="checkbox" name="inactive" value="1" <?=($_POST['inactive'] == 1)?'checked':''?> > Include inactive Health funds
					</div>
				</form>
			</div>
		</div>

		<!-- Tablelist Section -->
	    <div class="col-md-12">
	      	<div class="well co">
	        	<table class="table">
	          		<thead>
			            <tr>
			            	<th style="width:50px">ID</th>
							<th style="width:300px">Label</th>
							<th style="width:100px">Status</th>
			            </tr>
	          		</thead>
	          		<tbody>
	          			<?php if($cntrows > 0){ ?>
							<?php while($row = $healthObj->fetchAssoc()) {
								$inactiveClass = ($row['active'] > 0)? "":"inactive";?>
			            		<?php
			            			$edit 	= fetchEditFormParameters($row['id'], $row['label']);
			            			$delete = fetchDeleteFormParameters($row['id'], $row['label']);
								?>
			            		<tr class="tr_<?=$row['id']?>" onClick="selectListRow('<?=$row['id']?>','<?=$edit?>','<?=$delete?>')">
					              	<td><?=$row['id']?></td>
									<td><?=$row['label']?></td>
									<td><?=($row['active']) ? 'Active' : 'Inactive';?></td>
			            		</tr>
			            	<?php } //end of loop ?>
						<?php } //end of count check ?>

	          		</tbody>
	        	</table>
	  		</div>
	    </div>
	    <br clear="all" />

	    <!-- Pagination Links -->
	    <div id="pagination">
			<?if($cntrows > 0){ 
				echo $healthObj->buildNavigation("healthfundtype"); 
			} else {?>
				<p>No results found</p>
			<? } ?>
		</div>
	
	    <!-- Button Sections -->
		<?include("pages/common/formButtons.php");?>
		
	</div>
</div>

<!-- Dialog box pop-ups -->
<div id="editDiv" title="Update Details" style="display:none;">
    <iframe id="edit" width="380" height="150" style="overflow:hidden" seamless="seamless" scrolling="no"></iframe>
</div>